import { BaseCommand } from "./BaseCommand";
import { API_EVENT, COMMAND_STATUS } from "@/FrontProcessing/interface";
/**
 * @description 隐藏所有网格对象
 */
export class Cmd_Mesh_Hide_All extends BaseCommand {
  event = API_EVENT.MESH_HIDE_ALL;
  execute(): Promise<any> {
    this.system.history.push(this);
    return new Promise((resolve) => {
      this.status = COMMAND_STATUS.RUNNING;
      this.system.hide_all_mesh();
      this.status = COMMAND_STATUS.FINISHED;
      resolve(true);
    });
  }

  undo(): boolean {
    return false;
  }
}
